package com.gitee.zeric.codec.generaters;

import cn.hutool.core.util.IdUtil;
import com.alibaba.fastjson.JSONObject;
import lombok.extern.slf4j.Slf4j;

/**
 * @author zj
 * @date 2021/12/13
 * uuid生成器
 */
@Slf4j
public class UUIDGenerater extends AbstractCodeGerator {

    @Override
    public String generate(String ruleCode,JSONObject param)  {
        return IdUtil.simpleUUID();
    }

    @Override
    protected String[] fields() {
        return new String[0];
    }

    @Override
    public int size(JSONObject paramJson) {
        return 32;
    }
}
